<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd">

<html lang="en">
<head>

<meta name="generator" content="PHPDoctor 2RC2 (http://phpdoctor.sourceforge.net/)">
<meta name="when" content="Tue, 09 Dec 2008 09:11:43 +0000">

<link rel="stylesheet" type="text/css" href="../stylesheet.css">
<link rel="start" href="../overview-summary.html">

<title>Graph (Moriarty)</title>

</head>
<body id="definition" onload="parent.document.title=document.title;">

<div class="header">
<h1>Moriarty</h1>
<ul>
<li><a href="../overview-summary.html">Overview</a></li>
<li><a href="../moriarty/package-summary.html">Package</a></li>
<li class="active">Class</li>
<li><a href="../moriarty/package-tree.html">Tree</a></li>
<li><a href="../deprecated-list.html">Deprecated</a></li>
<li><a href="../index-all.html">Index</a></li>
</ul>
</div>

<div class="small_links">
<a href="../index.html" target="_top">Frames</a>
<a href="../moriarty/graph.html" target="_top">No frames</a>
</div>
<div class="small_links">
Summary: <a href="#summary_field">Field</a> | <a href="#summary_method">Method</a> | <a href="#summary_constr">Constr</a>
Detail: <a href="#detail_field">Field</a> | <a href="#detail_method">Method</a> | <a href="#summary_constr">Constr</a>
</div>
<hr>

<div class="qualifiedName">Moriarty.Graph</div>

<h1>Class Graph</h1>

<pre class="tree"><strong>Graph</strong><br /></pre>

<hr>

<p class="signature">public  class <strong>Graph</strong></p>

<div class="comment" id="overview_description"><p>
The base class for graphs in a store.
/</p></div>

<hr>

<table id="summary_constr">
<tr><th colspan="2">Constructor Summary</th></tr>
<tr>
<td class="description"><p class="name"><a href="#Graph()">Graph</a>(string uri, <a href="../moriarty/credentials.html">Credentials</a> credentials)</p><p class="description">
Create a new instance of this class</p></td>
</tr>
</table>

<table id="summary_method">
<tr><th colspan="2">Method Summary</th></tr>
<tr>
<td class="type"> <a href="../moriarty/httpresponse.html">HttpResponse</a></td>
<td class="description"><p class="name"><a href="#apply_changeset()">apply_changeset</a>(<a href="../moriarty/changeset.html">ChangeSet</a> cs)</p><p class="description">
Apply a changeset to the graph</p></td>
</tr>
<tr>
<td class="type"> <a href="../moriarty/httpresponse.html">HttpResponse</a></td>
<td class="description"><p class="name"><a href="#apply_changeset_rdfxml()">apply_changeset_rdfxml</a>(string rdfxml)</p><p class="description">
Apply a changeset to the graph</p></td>
</tr>
<tr>
<td class="type"> <a href="../moriarty/httpresponse.html">HttpResponse</a></td>
<td class="description"><p class="name"><a href="#apply_versioned_changeset()">apply_versioned_changeset</a>(<a href="../moriarty/changeset.html">ChangeSet</a> cs)</p><p class="description">
Apply a changeset in a versioned manner to the graph</p></td>
</tr>
<tr>
<td class="type"> <a href="../moriarty/httpresponse.html">HttpResponse</a></td>
<td class="description"><p class="name"><a href="#apply_versioned_changeset_rdfxml()">apply_versioned_changeset_rdfxml</a>(string rdfxml)</p><p class="description">
Apply a changeset in a versioned manner to the graph</p></td>
</tr>
<tr>
<td class="type"> <a href="../moriarty/httpresponse.html">HttpResponse</a></td>
<td class="description"><p class="name"><a href="#describe()">describe</a>(string uri, string output)</p><p class="description">
Obtain the graph's bounded description of a given resource</p></td>
</tr>
<tr>
<td class="type"> <a href="../moriarty/simplegraph.html">SimpleGraph</a></td>
<td class="description"><p class="name"><a href="#describe_to_simple_graph()">describe_to_simple_graph</a>(string uri)</p><p class="description">
Obtain the graph's bounded description of a given resource. </p></td>
</tr>
<tr>
<td class="type"> void</td>
<td class="description"><p class="name"><a href="#describe_to_triple_list()">describe_to_triple_list</a>(mixed uri)</p><p class="description">
Obtain the graph's bounded description of a given resource</p></td>
</tr>
<tr>
<td class="type"> boolean</td>
<td class="description"><p class="name"><a href="#has_description()">has_description</a>(string uri)</p><p class="description">
Tests whether the graph contains a bounded description of a given resource. </p></td>
</tr>
<tr>
<td class="type"> <a href="../moriarty/httpresponse.html">HttpResponse</a></td>
<td class="description"><p class="name"><a href="#submit_rdfxml()">submit_rdfxml</a>(string rdfxml)</p><p class="description">
Submit some RDF/XML to be added to the graph</p></td>
</tr>
</table>

<h2 id="detail_constr">Constructor Detail</h2>
<h3 id="Graph()">Graph</h3>
<code class="signature">public <strong>Graph</strong>(string uri, <a href="../moriarty/credentials.html">Credentials</a> credentials)</code>
<div class="details">
<p>
Create a new instance of this class</p><dl>
<dt>Parameters:</dt>
<dd>uri - URI of the graph</dd>
<dd>credentials - the credentials to use for authenticated requests (optional)</dd>
</dl>
</div>

<hr>

<h2 id="detail_method">Method Detail</h2>
<h3 id="apply_changeset()">apply_changeset</h3>
<code class="signature">public  <a href="../moriarty/httpresponse.html">HttpResponse</a> <strong>apply_changeset</strong>(<a href="../moriarty/changeset.html">ChangeSet</a> cs)</code>
<div class="details">
<p>
Apply a changeset to the graph</p><dl>
<dt>Parameters:</dt>
<dd>cs - the changeset to apply</dd>
</dl>
</div>

<hr>

<h3 id="apply_changeset_rdfxml()">apply_changeset_rdfxml</h3>
<code class="signature">public  <a href="../moriarty/httpresponse.html">HttpResponse</a> <strong>apply_changeset_rdfxml</strong>(string rdfxml)</code>
<div class="details">
<p>
Apply a changeset to the graph</p><dl>
<dt>Parameters:</dt>
<dd>rdfxml - the changeset to apply, serialised as RDF/XML</dd>
</dl>
</div>

<hr>

<h3 id="apply_versioned_changeset()">apply_versioned_changeset</h3>
<code class="signature">public  <a href="../moriarty/httpresponse.html">HttpResponse</a> <strong>apply_versioned_changeset</strong>(<a href="../moriarty/changeset.html">ChangeSet</a> cs)</code>
<div class="details">
<p>
Apply a changeset in a versioned manner to the graph</p><dl>
<dt>Parameters:</dt>
<dd>cs - the changeset to apply</dd>
</dl>
</div>

<hr>

<h3 id="apply_versioned_changeset_rdfxml()">apply_versioned_changeset_rdfxml</h3>
<code class="signature">public  <a href="../moriarty/httpresponse.html">HttpResponse</a> <strong>apply_versioned_changeset_rdfxml</strong>(string rdfxml)</code>
<div class="details">
<p>
Apply a changeset in a versioned manner to the graph</p><dl>
<dt>Parameters:</dt>
<dd>rdfxml - the changeset to apply, serialised as RDF/XML</dd>
</dl>
</div>

<hr>

<h3 id="describe()">describe</h3>
<code class="signature">public  <a href="../moriarty/httpresponse.html">HttpResponse</a> <strong>describe</strong>(string uri, string output)</code>
<div class="details">
<p>
Obtain the graph's bounded description of a given resource</p><dl>
<dt>See Also:</dt>
<dd><a href="http://n2.talis.com/wiki/Metabox#Describing_a_Resource">http://n2.talis.com/wiki/Metabox#Describing_a_Resource</a></dd>
<dt>Parameters:</dt>
<dd>uri - the URI of the resource to be described</dd>
<dd>output - the desired output format of the response (e.g. rdf, xml, json, ntriples, turtle)</dd>
</dl>
</div>

<hr>

<h3 id="describe_to_simple_graph()">describe_to_simple_graph</h3>
<code class="signature">public  <a href="../moriarty/simplegraph.html">SimpleGraph</a> <strong>describe_to_simple_graph</strong>(string uri)</code>
<div class="details">
<p>
Obtain the graph's bounded description of a given resource. This is designed to be fast since it uses RDF/JSON which requires no parsing by the SimpleGraph class. This method always returns a SimpleGraph, which will be empty if any HTTP errors occured.</p><dl>
<dt>See Also:</dt>
<dd><a href="http://n2.talis.com/wiki/Metabox#Describing_a_Resource">http://n2.talis.com/wiki/Metabox#Describing_a_Resource</a></dd>
<dt>Parameters:</dt>
<dd>uri - the URI of the resource to be described</dd>
</dl>
</div>

<hr>

<h3 id="describe_to_triple_list()">describe_to_triple_list</h3>
<code class="signature">public  void <strong>describe_to_triple_list</strong>(mixed uri)</code>
<div class="details">
<p>
Obtain the graph's bounded description of a given resource</p><dl>
<dt>Deprecated:</dt>
<dd>triple lists are deprecated</dd>
</dl>
</div>

<hr>

<h3 id="has_description()">has_description</h3>
<code class="signature">public  boolean <strong>has_description</strong>(string uri)</code>
<div class="details">
<p>
Tests whether the graph contains a bounded description of a given resource. This uses a conditional GET.</p><dl>
<dt>See Also:</dt>
<dd><a href="http://n2.talis.com/wiki/Metabox#Describing_a_Resource">http://n2.talis.com/wiki/Metabox#Describing_a_Resource</a></dd>
<dt>Parameters:</dt>
<dd>uri - the URI of the resource to be described</dd>
<dt>Returns:</dt>
<dd>true if the graph contains triples with the resource as a subject, false otherwise</dd>
</dl>
</div>

<hr>

<h3 id="submit_rdfxml()">submit_rdfxml</h3>
<code class="signature">public  <a href="../moriarty/httpresponse.html">HttpResponse</a> <strong>submit_rdfxml</strong>(string rdfxml)</code>
<div class="details">
<p>
Submit some RDF/XML to be added to the graph</p><dl>
<dt>Parameters:</dt>
<dd>rdfxml - the RDF to be submitted, serialised as RDF/XML</dd>
</dl>
</div>

<hr>

<div class="header">
<h1>Moriarty</h1>
<ul>
<li><a href="../overview-summary.html">Overview</a></li>
<li><a href="../moriarty/package-summary.html">Package</a></li>
<li class="active">Class</li>
<li><a href="../moriarty/package-tree.html">Tree</a></li>
<li><a href="../deprecated-list.html">Deprecated</a></li>
<li><a href="../index-all.html">Index</a></li>
</ul>
</div>

<div class="small_links">
<a href="../index.html" target="_top">Frames</a>
<a href="../moriarty/graph.html" target="_top">No frames</a>
</div>
<div class="small_links">
Summary: <a href="#summary_field">Field</a> | <a href="#summary_method">Method</a> | <a href="#summary_constr">Constr</a>
Detail: <a href="#detail_field">Field</a> | <a href="#detail_method">Method</a> | <a href="#summary_constr">Constr</a>
</div>
<hr>

<p id="footer">This document was generated by <a href="http://phpdoctor.sourceforge.net/">PHPDoctor: The PHP Documentation Creator</a></p>

</body>

</html>